package com.chengjj.kings.core.log;

import com.chengjj.kings.core.util.SpringContextHolder;
import org.springframework.stereotype.Component;
import org.springframework.web.context.WebApplicationContext;

import java.io.Serializable;

import org.springframework.context.annotation.Scope;


/**
 * @Author: 成俊杰
 * @CreateDate: 2019/3/14
 * @Version: 1.0
 * @Description:
 */
@Component
@Scope(scopeName = WebApplicationContext.SCOPE_SESSION)
public class LogObjectHolder implements Serializable {

    private Object object = null;

    public Object get() {
        return object;
    }

    public void setObject(Object object) {
        this.object = object;
    }

    public static LogObjectHolder me() {
        return SpringContextHolder.getBean(LogObjectHolder.class);
    }

}
